package org.jypj.dev.model;

import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.google.gson.Gson;

/**
 * 用户表
 *
 * @author chenyu
 */
public class User implements java.io.Serializable {

    private static final long serialVersionUID = 1L;

    private String id; //主键
    private String userNum; //人员编号(工号)
    private String username; //用户姓名
    private String simplePinYin;//拼音简拼
    private String fullPinYin;//拼音全拼
    private String trainType;//上岗资质
    private String password; //密码
    private String passwordMd5; //MD加密密码
    private String imagePath; //头像地址
    private String facePath; //人脸识别的特征图像地址
    private String depNum; //所属部门编号
    private String roleType; //角色类型
    private String phoneNum;//手机号
    private String createDate; //创建时间
    private String modifyDate; //修改时间
    private String token; //接口校验（用户名+密码的MD5）

    private String roleName;//角色名称
    private String searchKey;// 用来搜索使用
    private List<Menu> menus;// 用户菜单
    private String workTypeName;// 工种名称
    private String depName;//部门名称

    private String giveWorkId;//派班表的ID
    private String giveWorkRemindTime;//叫班时间
    private String trainNum;//派班车组号
    private int hadRemind;//是否已经提醒

    private Map<String, String> trainTypeNames = new HashMap<>();// 车型

    public User() {
        super();
    }

    public User(String userNum, String password) {
        super();
        this.password = password;
        this.userNum = userNum;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getUserNum() {
        return userNum;
    }

    public void setUserNum(String userNum) {
        this.userNum = userNum;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getDepNum() {
        return depNum;
    }

    public void setDepNum(String depNum) {
        this.depNum = depNum;
    }

    public String getImagePath() {
        return imagePath;
    }

    public void setImagePath(String imagePath) {
        this.imagePath = imagePath;
    }

    public String getRoleType() {
        return roleType;
    }

    public void setRoleType(String roleType) {
        this.roleType = roleType;
    }

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getSearchKey() {
        return searchKey;
    }

    public void setSearchKey(String searchKey) {
        this.searchKey = searchKey;
    }

    public List<Menu> getMenus() {
        return menus;
    }

    public void setMenus(List<Menu> menus) {
        this.menus = menus;
    }

    public String getWorkTypeName() {
        return workTypeName;
    }

    public void setWorkTypeName(String workTypeName) {
        this.workTypeName = workTypeName;
    }

    public String getDepName() {
        return depName;
    }

    public void setDepName(String depName) {
        this.depName = depName;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public String getGiveWorkId() {
        return giveWorkId;
    }

    public void setGiveWorkId(String giveWorkId) {
        this.giveWorkId = giveWorkId;
    }

    public String getGiveWorkRemindTime() {
        return giveWorkRemindTime;
    }

    public void setGiveWorkRemindTime(String giveWorkRemindTime) {
        this.giveWorkRemindTime = giveWorkRemindTime;
    }

    public String getPasswordMd5() {
        return passwordMd5;
    }

    public void setPasswordMd5(String passwordMd5) {
        this.passwordMd5 = passwordMd5;
    }

    public String getFacePath() {
        return facePath;
    }

    public void setFacePath(String facePath) {
        this.facePath = facePath;
    }

    public String getCreateDate() {
        return createDate;
    }

    public void setCreateDate(String createDate) {
        this.createDate = createDate;
    }

    public String getModifyDate() {
        return modifyDate;
    }

    public void setModifyDate(String modifyDate) {
        this.modifyDate = modifyDate;
    }

    public String getTrainNum() {
        return trainNum;
    }

    public void setTrainNum(String trainNum) {
        this.trainNum = trainNum;
    }

    public String getPhoneNum() {
        return phoneNum;
    }

    public void setPhoneNum(String phoneNum) {
        this.phoneNum = phoneNum;
    }

    public int getHadRemind() {
        return hadRemind;
    }

    public void setHadRemind(int hadRemind) {
        this.hadRemind = hadRemind;
    }

    public String getSimplePinYin() {
        return simplePinYin;
    }

    public void setSimplePinYin(String simplePinYin) {
        this.simplePinYin = simplePinYin;
    }

    public String getFullPinYin() {
        return fullPinYin;
    }

    public void setFullPinYin(String fullPinYin) {
        this.fullPinYin = fullPinYin;
    }

    public String getTrainType() {
        return trainType;
    }

    public void setTrainType(String trainType) {
        this.trainType = trainType;
    }

    public Map<String, String> getTrainTypeNames() {
        return trainTypeNames;
    }

    public void setTrainTypeNames(Map<String, String> trainTypeNames) {
        this.trainTypeNames = trainTypeNames;
    }

    @Override
    public String toString() {
        Gson gson = new Gson();
        return gson.toJson(this);
    }

}